package builders;

import force.GlobalForce;
import force.WallRepulsion;
import java.util.LinkedList;
import main.Simulation;

/**
 * 
 * Builds wall forces.
 * @author Paul
 * @author Lance
 */
public class WallBuilder extends GlobalForceBuilder {

    @Override
    public void build(Simulation sim, LinkedList<Double> properties) {
        int id = (int)(double)properties.poll();
        double magnitude = properties.poll();
        double exponentValue = properties.poll();

        GlobalForce force = new WallRepulsion(id, exponentValue, 
                magnitude, sim);
        addForces(sim, force);
    }

}
